8c4159e5f0287f90d2c866c7547b07959b249db7,sonar-server/src/main/java/org/sonar/server/rule/RuleRegistry.java,RuleRegistry,bulkIndexActiveRules,#List#Multimap#,314

Before Change


        parentIds[index] = activeRule.getRulId().toString();
        index++;
      }
      searchIndex.bulkIndex(INDEX_RULES, TYPE_ACTIVE_RULE, ids, docs, parentIds);
    } catch (IOException e) {
      throw new IllegalStateException("Unable to index active rules", e);
    }

After Change


        parentIds[index] = activeRule.getRulId().toString();
        index++;
      }
      if (! activeRules.isEmpty()) {
        searchIndex.bulkIndex(INDEX_RULES, TYPE_ACTIVE_RULE, ids, docs, parentIds);
      }
    } catch (IOException e) {
      throw new IllegalStateException("Unable to index active rules", e);